﻿using System;
using System.Collections.Generic;
using UnityEngine;

namespace WorldMapNew
{
    /// <summary>
    /// 地图数据结构
    /// </summary>
    public class MapPrefabMap : ScriptableObject
    {
        public List<PrefabData> mapPrefabMap;                //层级缩放策略数据 -存储当前地图使用到的层级 和 该层级对应的lod

        public MapPrefabMap()
        {
            mapPrefabMap = new List<PrefabData>();
        }

        public void AddMapPrefabMap(PrefabData data)
        {
            mapPrefabMap.Add(data);
        }
    }
    
    /// <summary>
    /// 序列化的资源数据
    /// </summary>
    [Serializable]
    public class PrefabData
    {
        public int resID;
        public string resPath;
        public int poolNum = 0;
        public int loadLevel = 1;
        public PrefabData(int resID, string resPath,int poolNum,int loadLevel = 1)
        {
            this.resID = resID;
            this.resPath = resPath;
            this.poolNum = poolNum;
            this.loadLevel = loadLevel;
        }
    }
}